<include file="Public:header" />
<p class="line" style="margin-top:0;"></p>
<div class="title_h2">搜索</div>
<form action="{:U('Oauth/index')}" method="get" id="searchform">
    <if condition="$Think.config.URL_MODE eq 0">
        <input type="hidden" name="c" value="{$Think.CONTROLLER_NAME}" />
        <input type="hidden" name="a" value="{$Think.ACTION_NAME}" />
    </if>
    <input type="hidden" name="uname_like" value="1" />
    <input type="hidden" name="nickname_like" value="1" />
    <input type="hidden" name="_order" id="_order" value="{$order}" />
    <input type="hidden" name="_sort" id="_sort" value="{$sort}" />
    <div class="filed fl">
        <select name="site">
            <option value="">平台接口</option>
            <volist name="oauth" id="vo">
                <option value="{$key}" <eq name="Think.get.site" value="$key"> selected=selected</eq>>{$vo.name}</option>
            </volist>
        </select>
        <select name="fieldskey">
            <option value="uname" <eq name="Think.get.fieldskey" value="uname"> selected=selected</eq>>会员名</option>
            <option value="nickname" <eq name="Think.get.fieldskey" value="nickname"> selected=selected</eq>>昵称</option>
        </select>
        <input type="text" name="fieldsvalue" value="{$Think.get.fieldsvalue}"/>
    </div>
    <div class="filed fl">
        <input type="submit" name="dosubmit" class="button" value="" />
    </div>
</form>
<div class="tablelist">
    <form action="{:U('Oauth/delete')}" method="post">
        <table class="table">
            <tr>
                <th colspan="10" class="top_th"></th>
            </tr>
            <tr>
                <th width="40"><input type="checkbox" id="check_box" onclick="selectall('id[]');"/></th>
                <th width="60">头像</th>
                <th width="100">昵称</th>
                <th width="80">会员名</th>
                <th width="100">平台</th>
                <th width="120">{:getSort('绑定时间', 'addtime', $order, $sortImg)}</th>
                <th width="120">{:getSort('上次登录', 'logintime', $order, $sortImg)}</th>
                <th width="80">{:getSort('登录次数', 'logintimes', $order, $sortImg)}</th>
                <th>管理操作</th>
            </tr>
            <tbody>
            <volist name="list" id="vo">
                <tr>
                    <td><input type="checkbox" name="id[]" value="{$vo['id']}"></td>
                    <td><if condition="$vo['url'] neq ''"><a href="{$vo['url']}" target="_blank"></if><img src="<if condition="$vo['avatar'] neq ''">{$vo['avatar']}<else />__PUBLIC__/Admin/Images/oauth/avatar.png</if>"><if condition="$vo['url'] neq ''"></a></if></td>
                <td><if condition="$vo['url'] neq ''"><a href="{$vo['url']}" target="_blank"></if>{$vo['nickname']}<if condition="$vo['url'] neq ''"></a></if></td>
                <td>{$vo.uname}</td>
                <td><img src="__PUBLIC__/Admin/Images/oauth/{$vo['site']}.png" align="absmiddle"/> {$oauth[$vo['site']]['name']}</td>
                <td>{$vo['addtime']|date="Y-m-d H:i",###}</td>
                <td>{$vo['logintime']|date="Y-m-d H:i",###}</td>
                <td>{$vo['logintimes']}</td>
                <td><a href="{:U('Oauth/delete?id='.$vo['id'])}" onclick="return confirm('确定要解除会员绑定吗？');">{:getIcon('del','解除绑定')}</a></td>
                </tr>
            </volist>
            <tr><td colspan="10">
                    <input type="submit" class="button" name="dosubmit" value=" 解除绑定 " onclick="return confirm('确定要解除会员绑定吗？');"/>
                </td></tr>
            </tbody>
        </table>
    </form>
    <div id="pages">{$page}</div>
</div>
<include file="Public:footer" />